<?php $users_history = View::get('users_history'); ?>

<div class="clear"></div>
<div class="round">
    <div class="round-head">
                <h2>Lista demotywatorów</h2>
                <div class="right"> 
                        <a class="filter-button" href="" title="Add filters">Add filters</a>
                        <input class="search" type="text" value="Search..." onclick="this.value=''" title="Search string" /> 
                </div>
        </div>


        <div class="round-content">

                <div class="hidden filter-boxes">

                        <form>

                                <div class="filter-item">
                                        <label>Name</label>
                                        <input type="text" />
                                </div>

                                <div class="filter-item">
                                        <label>Type</label>
                                        <select multiple="multiple"><option>All records</option><option>Only publicated</option><option>Only deleted</option></select>
                                </div>

                                <div class="filter-item">
                                        <label>Publication date</label>
                                        From: <input class="date-input" type="text" />
                                        To: <input class="date-input" type="text" />
                                </div>

                                <div class="cl">
                                        <input type="button" class="btn filter-send" value="Filter results" /> <a class="filter-reset-button" href="" title="Reset filters">Reset filters</a> | <a class="filter-button" href="" title="Hide filters">Hide filters</a>
                                </div>

                        </form>

                </div>

                <table class="table-a" summary="Table">
                        <thead>
                                <tr>
                                        <th scope="col" class="chb"><input class="chall" type="checkbox" /></th>
                                        <th scope="col">ID</th>
                                        <th scope="col">Kontroler</th>
                                        <th scope="col">Akcja</th>
                                        <th scope="col">Timestamp</th>
                                        <th scope="col">IP</th>
                                        <th scope="col">User</th>
                                        <th scope="col" style="width: 65px;">Options</th>
                                </tr>
                        </thead>

                        <tbody>
                            <?php foreach ($users_history as $d): ?>
                                <tr>
                                        <td><input type="checkbox" /></td>
                                        <td><?php echo $d['id']; ?></td>
                                        <td><?php echo $d['controller']; ?></td>
                                        <td><?php echo $d['action']; ?></td>
                                        <td><?php echo $d['date']; ?></td>
                                        <td><?php echo $d['ip']; ?></td>
                                        <td><?php echo $d['login']; ?> </td>
                                        <td>
                                                <a href="index.php?controller=demot&action=edit&id=<?php echo $d['id']; ?>" class="table-icon edit" title="Edit"></a>
                                                <a href="index.php?controller=demot&action=delete&id=<?php echo $d['id']; ?>" class="table-icon delete" title="Delete"></a>
                                                <a href="index.php?controller=demot&action=delete" class="table-icon download" title="Download"></a>
                                        </td>
                                </tr>
                            <?php endforeach; ?>
                                
                        </tbody>
                </table>

                <div class="tab-bottom-menu">
                        <h4>Change status for selected items:</h4>

                        <ul>
                                <li><select><option>Select new bonus</option><option>10$</option><option>20$</option><option>30$</option><option>50$</option></select> <a href="#" class="btn btn-gray">Save</a></li> 
                        </ul> 

                </div>
            <!--
                <div class="tab-summary">

                        <div class="pagination-count">
                                <strong>Page 1 of 6 </strong>
                                <span class="s">Users: 1 - 1 of 6</span>
                        </div>

                        <div class="pagination">
                                <div class="resultsInfo">
                                        <span class="first">« First</span>
                                        <span class="prev">‹ Prev</span>
                                        <span class="active">1</span>
                                        <a href="#2">2</a>
                                        <a href="#3">3</a>
                                        <a class="next" href="#next">Next ›</a>
                                        <a class="last" href="#last">Last »</a>
                                </div>

                        </div>

                        <div class="closePagination"></div>

                </div>
                -->

        </div>

</div>